<%@page contentType="text/html"%>
<%@page pageEncoding="UTF-8"%>

<%@taglib prefix="f" uri="http://java.sun.com/jsf/core"%>
<%@taglib prefix="h" uri="http://java.sun.com/jsf/html"%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">

<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>JSP Page</title>
    </head>
    <body>
        <f:view>
            <h1><h:outputText value="JavaServer Faces" /></h1>
        </f:view>
        <f:view>
            <h:form>
                <h1><h:outputText value="List"/></h1>
                <h:dataTable value="#{users.all}" var="item">
                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="IdUsers"/>
                        </f:facet>
                        <h:outputText value="#{item.idUsers}"/>
                    </h:column>
                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="Lastname"/>
                        </f:facet>
                        <h:outputText value="#{item.lastname}"/>
                    </h:column>
                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="RegistrationDate"/>
                        </f:facet>
                        <h:outputText value="#{item.registrationDate}">
                            <f:convertDateTime type="TIMESTAMP" pattern="MM/dd/yyyy, hh:mm:ss" />
                        </h:outputText>
                    </h:column>
                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="Password"/>
                        </f:facet>
                        <h:outputText value="#{item.password}"/>
                    </h:column>
                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="ActivationDate"/>
                        </f:facet>
                        <h:outputText value="#{item.activationDate}">
                            <f:convertDateTime type="TIMESTAMP" pattern="MM/dd/yyyy, hh:mm:ss" />
                        </h:outputText>
                    </h:column>
                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="Username"/>
                        </f:facet>
                        <h:outputText value="#{item.username}"/>
                    </h:column>
                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="ExpirationDate"/>
                        </f:facet>
                        <h:outputText value="#{item.expirationDate}">
                            <f:convertDateTime type="TIMESTAMP" pattern="MM/dd/yyyy, hh:mm:ss" />
                        </h:outputText>
                    </h:column>
                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="Firstname"/>
                        </f:facet>
                        <h:outputText value="#{item.firstname}"/>
                    </h:column>
                    <h:column>
                        <f:facet name="header">
                            <h:outputText value="UserGroup"/>
                        </f:facet>
                        <h:outputText value="#{item.userGroup}"/>
                    </h:column>
                </h:dataTable>
            </h:form>
        </f:view>
        
     
        
        
        
    </body>
</html>
